/*
 * @Author: Bonnie
 * @Date: 2021-08-30 15:31:17
 * @LastEditTime: 2021-10-12 18:07:51
 * @LastEditors: Bonnie
 * @Description:
 * @FilePath: /custom/src/router/index.js
 */
import Vue from "vue";
import VueRouter from "vue-router";

Vue.use(VueRouter);

const routes = [
  {
    path: "/",
    redirect: "/home",
  },
  {
    path: "/home",
    name: "Home",
    component: () => import("../views/Home.vue"),
  },
  {
    path: "/layout",
    name: "Layout",
    component: () => import("../views/Layout.vue"),
  },
  {
    path: "/loader-css",
    name: "LoaderCss",
    component: () => import("../views/LoaderCss.vue"),
  },
  {
    path: "/css",
    name: "CssSpinners",
    component: () => import("../views/CssSpinners.vue"),
  },
  {
    path: "/test",
    name: "Test",
    component: () => import("../views/Test.vue"),
  },
  {
    path: "/*",
    name: "404",
    component: () => import("../views/NotFound.vue"),
  },
];

const router = new VueRouter({
  mode: "history",
  base: process.env.BASE_URL,
  routes,
});

export default router;
